//
//  ViewCenter.m
//  Pitch
//
//  Created by zhujinhui on 14-9-1.
//  Copyright (c) 2014年 zhujinhui. All rights reserved.
//

#import "ViewCenter.h"

@implementation ViewCenter

static ViewCenter *instance;

+(ViewCenter *) shareInstance{
    if (!instance) {
        instance = [[ViewCenter alloc]init];
    }
    return instance;
}

//
-(BOOL) fromController:(UIViewController *)fvc
        nextController:(UIViewController * )nvc
               animate:(AnimateType) atype{
    switch (atype) {
        case AnimateTypeNone:{
            [fvc.navigationController pushViewController:nvc animated:NO];
        }
            break;
        case AnimateTypePush:{
            [fvc.navigationController pushViewController:nvc animated:YES];
        }
            
        default:
            break;
    }
    return TRUE;
}



@end
